package com.ea.admin.service;

import com.ea.admin.pojo.vo.account.AdminInfoVo;
import com.ea.admin.pojo.vo.auth.AuthVo;
import com.ea.common.auth.NowUser;

public interface AuthService {
    String USERNAME_TO_NOWUSER_REDIS_KEY_PREFIX = "USERNAME_TO_NOWUSER:";

    AuthVo login(String username, String password);

    Boolean checkPassword(String username, String password);

    void logout(Long accountId, String token);

    void changePassword(Long accountId, String oldPassword, String password, String token);

    AdminInfoVo getAdminInfo(Long accountId);

    NowUser getNowUserByUsername(String username);
}
